------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
      name:  <unnamed>
       log:  C:\Users\ericzou\Dropbox\replicate_smokelabor/2_analysis/output_logs/table1.log
  log type:  text
 opened on:  22 Jun 2022, 16:43:28

. 
.         use "$Rep_smokelabor/1_build/regdata/county_quarter.dta", clear 

. 
.         local tbl_settings_log format(%6.3f) parentheses(stderr) asterisk()

.         local tbl_settings_pmil format(%6.1f) parentheses(stderr) asterisk()

.         
.         ** panel a
.         if 1 {
.                 
.                 * pm2.5
.                 reghdfe pm25 hms_deep [aw=seer_pop], a(fe_countyqtroy fe_styr) vce(cluster countyfip fe_stqtros)
(dropped 189 singleton observations)
(MWFE estimator converged in 8 iterations)

HDFE Linear regression                            Number of obs   =     75,207
Absorbing 2 HDFE groups                           F(   1,   1685) =      71.70
Statistics robust to heteroskedasticity           Prob > F        =     0.0000
                                                  R-squared       =     0.7864
                                                  Adj R-squared   =     0.7634
Number of clusters (countyfip) =      1,686       Within R-sq.    =     0.0369
Number of clusters (fe_stqtros) =      2,548      Root MSE        =     1.3481

               (Std. Err. adjusted for 1,686 clusters in countyfip fe_stqtros)
------------------------------------------------------------------------------
             |               Robust
        pm25 |      Coef.   Std. Err.      t    P>|t|     [95% Conf. Interval]
-------------+----------------------------------------------------------------
    hms_deep |   .0556401   .0065709     8.47   0.000      .042752    .0685282
       _cons |   9.190593    .040427   227.34   0.000     9.111301    9.269886
------------------------------------------------------------------------------

Absorbed degrees of freedom:
--------------------------------------------------------+
    Absorbed FE | Categories  - Redundant  = Num. Coefs |
----------------+---------------------------------------|
 fe_countyqtroy |      6677        6677           0    *|
        fe_styr |       637           0         637     |
--------------------------------------------------------+
* = FE nested within cluster; treated as redundant for DoF computation
.                 summ pm25 [aw=seer_pop] if e(sample)

    Variable |     Obs      Weight        Mean   Std. Dev.       Min        Max
-------------+-----------------------------------------------------------------
        pm25 |  75,207  1.4030e+10    9.460657   2.771534  -4.008642   53.32418
.                 local ymean=`r(mean)'
.                 regsave using "$Rep_smokelabor/2_analysis/output_tables/table1_a.dta", addlabel(outcome_mean, "`ymean'") table(pm25, `tbl_settings_log') replace
file C:\Users\ericzou\Dropbox\replicate_smokelabor/2_analysis/output_tables/table1_a.dta saved
.                 
.                 * income 
.                 reghdfe d_pc_qwi_payroll hms_deep [aw=seer_pop], a(fe_countyqtroy fe_styr) vce(cluster countyfip fe_stqtros)
(MWFE estimator converged in 5 iterations)

HDFE Linear regression                            Number of obs   =    160,346
Absorbing 2 HDFE groups                           F(   1,   2519) =      45.21
Statistics robust to heteroskedasticity           Prob > F        =     0.0000
                                                  R-squared       =     0.2431
                                                  Adj R-squared   =     0.1760
Number of clusters (countyfip) =      3,106       Within R-sq.    =     0.0038
Number of clusters (fe_stqtros) =      2,520      Root MSE        =   409.6540

               (Std. Err. adjusted for 2,520 clusters in countyfip fe_stqtros)
------------------------------------------------------------------------------
             |               Robust
d_pc_qwi_p~l |      Coef.   Std. Err.      t    P>|t|     [95% Conf. Interval]
-------------+----------------------------------------------------------------
    hms_deep |  -5.216626   .7758234    -6.72   0.000    -6.737943   -3.695309
       _cons |    166.374   4.714186    35.29   0.000       157.13    175.6181
------------------------------------------------------------------------------

Absorbed degrees of freedom:
--------------------------------------------------------+
    Absorbed FE | Categories  - Redundant  = Num. Coefs |
----------------+---------------------------------------|
 fe_countyqtroy |     12424       12424           0    *|
        fe_styr |       631           0         631     |
--------------------------------------------------------+
* = FE nested within cluster; treated as redundant for DoF computation
.                 summ pc_qwi_payroll [aw=seer_pop] if e(sample)

    Variable |     Obs      Weight        Mean   Std. Dev.       Min        Max
-------------+-----------------------------------------------------------------
pc_qwi_pay~l | 160,346  1.6164e+10    5359.656   3673.911   214.6878   84978.36
.                 local ymean=`r(mean)'
.                 regsave using "$Rep_smokelabor/2_analysis/output_tables/table1_a.dta", addlabel(outcome_mean, "`ymean'") table(earnings, `tbl_settings_log') append
file C:\Users\ericzou\Dropbox\replicate_smokelabor/2_analysis/output_tables/table1_a.dta saved
.                 
.                 * emp 
.                 reghdfe d_pmil_qwi_emptotal hms_deep [aw=seer_pop16plus], a(fe_countyqtroy fe_styr) vce(cluster countyfip fe_stqtros)
(MWFE estimator converged in 5 iterations)

HDFE Linear regression                            Number of obs   =    160,346
Absorbing 2 HDFE groups                           F(   1,   2519) =      13.20
Statistics robust to heteroskedasticity           Prob > F        =     0.0003
                                                  R-squared       =     0.5293
                                                  Adj R-squared   =     0.4875
Number of clusters (countyfip) =      3,106       Within R-sq.    =     0.0005
Number of clusters (fe_stqtros) =      2,520      Root MSE        = 18020.2635

               (Std. Err. adjusted for 2,520 clusters in countyfip fe_stqtros)
------------------------------------------------------------------------------
             |               Robust
d_pmil_qwi~l |      Coef.   Std. Err.      t    P>|t|     [95% Conf. Interval]
-------------+----------------------------------------------------------------
    hms_deep |  -79.58788   21.90873    -3.63   0.000    -122.5488   -36.62692
       _cons |  -1395.351   134.9056   -10.34   0.000    -1659.888   -1130.813
------------------------------------------------------------------------------

Absorbed degrees of freedom:
--------------------------------------------------------+
    Absorbed FE | Categories  - Redundant  = Num. Coefs |
----------------+---------------------------------------|
 fe_countyqtroy |     12424       12424           0    *|
        fe_styr |       631           0         631     |
--------------------------------------------------------+
* = FE nested within cluster; treated as redundant for DoF computation
.                 summ pmil_qwi_emptotal [aw=seer_pop16plus] if e(sample)

    Variable |     Obs      Weight        Mean   Std. Dev.       Min        Max
-------------+-----------------------------------------------------------------
pmil_qwi_e~l | 160,346  1.2826e+10    625776.2   210332.4   70658.51    6745368
.                 local ymean=`r(mean)'
.                 regsave using "$Rep_smokelabor/2_analysis/output_tables/table1_a.dta", addlabel(outcome_mean, "`ymean'") table(employment, `tbl_settings_pmil') append
file C:\Users\ericzou\Dropbox\replicate_smokelabor/2_analysis/output_tables/table1_a.dta saved
.                 
.                 * lfp
.                 reghdfe d_pmil_lau_lfp hms_deep [aw=seer_pop] , a(fe_countyqtroy fe_styr) vce(cluster countyfip fe_stqtros)
(MWFE estimator converged in 4 iterations)

HDFE Linear regression                            Number of obs   =    161,498
Absorbing 2 HDFE groups                           F(   1,   2547) =      17.57
Statistics robust to heteroskedasticity           Prob > F        =     0.0000
                                                  R-squared       =     0.2403
                                                  Adj R-squared   =     0.1735
Number of clusters (countyfip) =      3,106       Within R-sq.    =     0.0003
Number of clusters (fe_stqtros) =      2,548      Root MSE        = 11151.6317

               (Std. Err. adjusted for 2,548 clusters in countyfip fe_stqtros)
------------------------------------------------------------------------------
             |               Robust
d_pmil_lau~p |      Coef.   Std. Err.      t    P>|t|     [95% Conf. Interval]
-------------+----------------------------------------------------------------
    hms_deep |  -38.70033   9.231539    -4.19   0.000    -56.80242   -20.59825
       _cons |  -1941.697   64.50074   -30.10   0.000    -2068.176   -1815.217
------------------------------------------------------------------------------

Absorbed degrees of freedom:
--------------------------------------------------------+
    Absorbed FE | Categories  - Redundant  = Num. Coefs |
----------------+---------------------------------------|
 fe_countyqtroy |     12424       12424           0    *|
        fe_styr |       637           0         637     |
--------------------------------------------------------+
* = FE nested within cluster; treated as redundant for DoF computation
.                 summ pmil_lau_lfp [aw=seer_pop] if e(sample)

    Variable |     Obs      Weight        Mean   Std. Dev.       Min        Max
-------------+-----------------------------------------------------------------
pmil_lau_lfp | 161,498  1.6302e+10    625434.2   60990.53   184521.2    4674419
.                 local ymean=`r(mean)'
.                 regsave using "$Rep_smokelabor/2_analysis/output_tables/table1_a.dta", addlabel(outcome_mean, "`ymean'") table(lfp, `tbl_settings_pmil') append
file C:\Users\ericzou\Dropbox\replicate_smokelabor/2_analysis/output_tables/table1_a.dta saved
.                 
.                 preserve 
.                         use "$Rep_smokelabor/2_analysis/output_tables/table1_a.dta", clear
.                         drop if var == "r2"
(1 observation deleted)
.                         drop if var == "_id"
(0 observations deleted)
.                         drop if strpos(var, "_cons_") > 0
(2 observations deleted)
.                         replace var="observations" if var=="N"
(1 real change made)
.                         ingap 3
.                         list , sep(0)

     +--------------------------------------------------------------+
     |             var       pm25    earnings   employ~t        lfp |
     |--------------------------------------------------------------|
  1. |   hms_deep_coef   0.056***   -5.217***   -79.6***   -38.7*** |
  2. | hms_deep_stderr    (0.007)     (0.776)     (21.9)      (9.2) |
  3. |                                                              |
  4. |    observations     75,207     160,346    160,346    161,498 |
  5. |    outcome_mean      9.461    5359.656   625776.2   625434.1 |
     +--------------------------------------------------------------+
.                         saveold "$Rep_smokelabor/2_analysis/output_tables/table1_a.dta", replace
(saving in Stata 13 format)
(FYI, saveold has options version(12) and version(11) that write files in older Stata formats)
file C:\Users\ericzou\Dropbox\replicate_smokelabor/2_analysis/output_tables/table1_a.dta saved
.                 restore 
.         }

.         
.         ** panel b
.         if 1 {
.         
.                 * income 
.                 reghdfe d_pc_qwi_payroll pm25  [aw=seer_pop], a(fe_countyqtroy fe_styr) vce(cluster countyfip fe_stqtros)
(dropped 187 singleton observations)
(MWFE estimator converged in 8 iterations)

HDFE Linear regression                            Number of obs   =     74,725
Absorbing 2 HDFE groups                           F(   1,   1684) =      11.70
Statistics robust to heteroskedasticity           Prob > F        =     0.0006
                                                  R-squared       =     0.3215
                                                  Adj R-squared   =     0.2480
Number of clusters (countyfip) =      1,685       Within R-sq.    =     0.0016
Number of clusters (fe_stqtros) =      2,520      Root MSE        =   360.2342

               (Std. Err. adjusted for 1,685 clusters in countyfip fe_stqtros)
------------------------------------------------------------------------------
             |               Robust
d_pc_qwi_p~l |      Coef.   Std. Err.      t    P>|t|     [95% Conf. Interval]
-------------+----------------------------------------------------------------
        pm25 |  -10.56581   3.089293    -3.42   0.001    -16.62507   -4.506551
       _cons |   249.7856   29.84766     8.37   0.000     191.2432     308.328
------------------------------------------------------------------------------

Absorbed degrees of freedom:
--------------------------------------------------------+
    Absorbed FE | Categories  - Redundant  = Num. Coefs |
----------------+---------------------------------------|
 fe_countyqtroy |      6676        6676           0    *|
        fe_styr |       631           0         631     |
--------------------------------------------------------+
* = FE nested within cluster; treated as redundant for DoF computation
.                 summ pc_qwi_payroll [aw=seer_pop] if e(sample)

    Variable |     Obs      Weight        Mean   Std. Dev.       Min        Max
-------------+-----------------------------------------------------------------
pc_qwi_pay~l |  74,725  1.3907e+10    5687.648   3805.212   534.9928   62888.39
.                 local ymean=`r(mean)'
.                 regsave using "$Rep_smokelabor/2_analysis/output_tables/table1_b.dta", addlabel(outcome_mean, "`ymean'") table(earnings, `tbl_settings_log') replace
file C:\Users\ericzou\Dropbox\replicate_smokelabor/2_analysis/output_tables/table1_b.dta saved
.                 
.                 * emp 
.                 reghdfe d_pmil_qwi_emptotal pm25 [aw=seer_pop16plus] , a(fe_countyqtroy fe_styr) vce(cluster countyfip fe_stqtros)
(dropped 187 singleton observations)
(MWFE estimator converged in 8 iterations)

HDFE Linear regression                            Number of obs   =     74,725
Absorbing 2 HDFE groups                           F(   1,   1684) =       5.25
Statistics robust to heteroskedasticity           Prob > F        =     0.0221
                                                  R-squared       =     0.6061
                                                  Adj R-squared   =     0.5634
Number of clusters (countyfip) =      1,685       Within R-sq.    =     0.0005
Number of clusters (fe_stqtros) =      2,520      Root MSE        = 16232.2919

               (Std. Err. adjusted for 1,685 clusters in countyfip fe_stqtros)
------------------------------------------------------------------------------
             |               Robust
d_pmil_qwi~l |      Coef.   Std. Err.      t    P>|t|     [95% Conf. Interval]
-------------+----------------------------------------------------------------
        pm25 |    -260.98   113.8954    -2.29   0.022    -484.3714   -37.58857
       _cons |   702.6454   1075.755     0.65   0.514    -1407.312    2812.603
------------------------------------------------------------------------------

Absorbed degrees of freedom:
--------------------------------------------------------+
    Absorbed FE | Categories  - Redundant  = Num. Coefs |
----------------+---------------------------------------|
 fe_countyqtroy |      6676        6676           0    *|
        fe_styr |       631           0         631     |
--------------------------------------------------------+
* = FE nested within cluster; treated as redundant for DoF computation
.                 summ pmil_qwi_emptotal [aw=seer_pop16plus] if e(sample)

    Variable |     Obs      Weight        Mean   Std. Dev.       Min        Max
-------------+-----------------------------------------------------------------
pmil_qwi_e~l |  74,725  1.1026e+10    643596.5   210020.4   120382.4    6745368
.                 local ymean=`r(mean)'
.                 regsave using "$Rep_smokelabor/2_analysis/output_tables/table1_b.dta", addlabel(outcome_mean, "`ymean'") table(employment, `tbl_settings_pmil') append
file C:\Users\ericzou\Dropbox\replicate_smokelabor/2_analysis/output_tables/table1_b.dta saved
.                 
.                 * lfp  
.                 reghdfe d_pmil_lau_lfp pm25 [aw=seer_pop] , a(fe_countyqtroy fe_styr) vce(cluster countyfip fe_stqtros)
(dropped 189 singleton observations)
(MWFE estimator converged in 8 iterations)

HDFE Linear regression                            Number of obs   =     75,193
Absorbing 2 HDFE groups                           F(   1,   1685) =       3.06
Statistics robust to heteroskedasticity           Prob > F        =     0.0806
                                                  R-squared       =     0.3115
                                                  Adj R-squared   =     0.2373
Number of clusters (countyfip) =      1,686       Within R-sq.    =     0.0002
Number of clusters (fe_stqtros) =      2,548      Root MSE        =  9424.6415

               (Std. Err. adjusted for 1,686 clusters in countyfip fe_stqtros)
------------------------------------------------------------------------------
             |               Robust
d_pmil_lau~p |      Coef.   Std. Err.      t    P>|t|     [95% Conf. Interval]
-------------+----------------------------------------------------------------
        pm25 |  -95.67996   54.72256    -1.75   0.081    -203.0113    11.65138
       _cons |  -1012.794   513.2569    -1.97   0.049    -2019.482   -6.105743
------------------------------------------------------------------------------

Absorbed degrees of freedom:
--------------------------------------------------------+
    Absorbed FE | Categories  - Redundant  = Num. Coefs |
----------------+---------------------------------------|
 fe_countyqtroy |      6677        6677           0    *|
        fe_styr |       637           0         637     |
--------------------------------------------------------+
* = FE nested within cluster; treated as redundant for DoF computation
.                 summ pmil_lau_lfp [aw=seer_pop] if e(sample)

    Variable |     Obs      Weight        Mean   Std. Dev.       Min        Max
-------------+-----------------------------------------------------------------
pmil_lau_lfp |  75,193  1.4027e+10    631805.5   54155.91   184521.2    1322149
.                 local ymean=`r(mean)'
.                 regsave using "$Rep_smokelabor/2_analysis/output_tables/table1_b.dta", addlabel(outcome_mean, "`ymean'") table(lfp, `tbl_settings_pmil') append
file C:\Users\ericzou\Dropbox\replicate_smokelabor/2_analysis/output_tables/table1_b.dta saved
.         
.                 preserve 
.                         use "$Rep_smokelabor/2_analysis/output_tables/table1_b.dta", clear
.                         drop if var == "r2"
(1 observation deleted)
.                         drop if var == "_id"
(0 observations deleted)
.                         drop if strpos(var, "_cons_") > 0
(2 observations deleted)
.                         replace var="observations" if var=="N"
(1 real change made)
.                         ingap 3
.                         list , sep(0)

     +-------------------------------------------------+
     |          var     earnings   employ~t        lfp |
     |-------------------------------------------------|
  1. |    pm25_coef   -10.566***   -261.0**     -95.7* |
  2. |  pm25_stderr      (3.089)    (113.9)     (54.7) |
  3. |                                                 |
  4. | observations       74,725     74,725     75,193 |
  5. | outcome_mean     5687.648   643596.5   631805.5 |
     +-------------------------------------------------+
.                         saveold "$Rep_smokelabor/2_analysis/output_tables/table1_b.dta", replace
(saving in Stata 13 format)
(FYI, saveold has options version(12) and version(11) that write files in older Stata formats)
file C:\Users\ericzou\Dropbox\replicate_smokelabor/2_analysis/output_tables/table1_b.dta saved
.                 restore
. }

.         
.         ** panel c
.         if 1 {
.                 
.                 * income
.                 ivreghdfe d_pc_qwi_payroll (pm25=hms_deep) [aw=seer_pop] , a(fe_countyqtroy fe_styr) cluster(countyfip fe_stqtros)
(dropped 187 singleton observations)
(sum of wgt is     1.3907e+10)
(MWFE estimator converged in 8 iterations)

IV (2SLS) estimation
--------------------

Estimates efficient for homoskedasticity only
Statistics robust to heteroskedasticity and clustering on countyfip and fe_stqtros

Number of clusters (countyfip) =   1685               Number of obs =    74725
Number of clusters (fe_stqtros) =   2520              F(  1,  1684) =    25.57
                                                      Prob > F      =   0.0000
Total (centered) SS     =   8762876942                Centered R2   =  -0.1232
Total (uncentered) SS   =   8762876942                Uncentered R2 =  -0.1232
Residual SS             =   9842095618                Root MSE      =    364.5

------------------------------------------------------------------------------
             |               Robust
d_pc_qwi_p~l |      Coef.   Std. Err.      t    P>|t|     [95% Conf. Interval]
-------------+----------------------------------------------------------------
        pm25 |  -103.0771   20.38598    -5.06   0.000    -143.0616   -63.09256
------------------------------------------------------------------------------
Underidentification test (Kleibergen-Paap rk LM statistic):             52.437
                                                   Chi-sq(1) P-val =    0.0000
------------------------------------------------------------------------------
Weak identification test (Cragg-Donald Wald F statistic):             2883.998
                         (Kleibergen-Paap rk Wald F statistic):         71.833
Stock-Yogo weak ID test critical values: 10% maximal IV size             16.38
                                         15% maximal IV size              8.96
                                         20% maximal IV size              6.66
                                         25% maximal IV size              5.53
Source: Stock-Yogo (2005).  Reproduced by permission.
NB: Critical values are for Cragg-Donald F statistic and i.i.d. errors.
------------------------------------------------------------------------------
Hansen J statistic (overidentification test of all instruments):         0.000
                                                 (equation exactly identified)
------------------------------------------------------------------------------
Instrumented:         pm25
Excluded instruments: hms_deep
Partialled-out:       _cons
                      nb: total SS, model F and R2s are after partialling-out;
                          any small-sample adjustments include partialled-out
                          variables in regressor count K
------------------------------------------------------------------------------

Absorbed degrees of freedom:
--------------------------------------------------------+
    Absorbed FE | Categories  - Redundant  = Num. Coefs |
----------------+---------------------------------------|
 fe_countyqtroy |      6676        6676           0    *|
        fe_styr |       631           0         631     |
--------------------------------------------------------+
* = FE nested within cluster; treated as redundant for DoF computation
.                 summ pc_qwi_payroll [aw=seer_pop] if e(sample)

    Variable |     Obs      Weight        Mean   Std. Dev.       Min        Max
-------------+-----------------------------------------------------------------
pc_qwi_pay~l |  74,725  1.3907e+10    5687.648   3805.212   534.9928   62888.39
.                 local ymean=`r(mean)'
.                 regsave using "$Rep_smokelabor/2_analysis/output_tables/table1_c.dta", addlabel(KleibergenPaap_F, `e(rkf)', outcome_mean, "`ymean'") table(earnings, `tbl_settings_pmil') replace
file C:\Users\ericzou\Dropbox\replicate_smokelabor/2_analysis/output_tables/table1_c.dta saved
.                 
.                 * emp
.                 ivreghdfe d_pmil_qwi_emptotal (pm25=hms_deep)  [aw=seer_pop16plus] , a(fe_countyqtroy fe_styr) cluster(countyfip fe_stqtros)
(dropped 187 singleton observations)
(sum of wgt is     1.1026e+10)
(MWFE estimator converged in 8 iterations)

IV (2SLS) estimation
--------------------

Estimates efficient for homoskedasticity only
Statistics robust to heteroskedasticity and clustering on countyfip and fe_stqtros

Number of clusters (countyfip) =   1685               Number of obs =    74725
Number of clusters (fe_stqtros) =   2520              F(  1,  1684) =    16.20
                                                      Prob > F      =   0.0001
Total (centered) SS     =  1.77722e+13                Centered R2   =  -0.0154
Total (uncentered) SS   =  1.77722e+13                Uncentered R2 =  -0.0154
Residual SS             =  1.80451e+13                Root MSE      =    15606

------------------------------------------------------------------------------
             |               Robust
d_pmil_qwi~l |      Coef.   Std. Err.      t    P>|t|     [95% Conf. Interval]
-------------+----------------------------------------------------------------
        pm25 |  -1750.101   434.8435    -4.02   0.000    -2602.992   -897.2105
------------------------------------------------------------------------------
Underidentification test (Kleibergen-Paap rk LM statistic):             52.204
                                                   Chi-sq(1) P-val =    0.0000
------------------------------------------------------------------------------
Weak identification test (Cragg-Donald Wald F statistic):             2892.275
                         (Kleibergen-Paap rk Wald F statistic):         71.151
Stock-Yogo weak ID test critical values: 10% maximal IV size             16.38
                                         15% maximal IV size              8.96
                                         20% maximal IV size              6.66
                                         25% maximal IV size              5.53
Source: Stock-Yogo (2005).  Reproduced by permission.
NB: Critical values are for Cragg-Donald F statistic and i.i.d. errors.
------------------------------------------------------------------------------
Hansen J statistic (overidentification test of all instruments):         0.000
                                                 (equation exactly identified)
------------------------------------------------------------------------------
Instrumented:         pm25
Excluded instruments: hms_deep
Partialled-out:       _cons
                      nb: total SS, model F and R2s are after partialling-out;
                          any small-sample adjustments include partialled-out
                          variables in regressor count K
------------------------------------------------------------------------------

Absorbed degrees of freedom:
--------------------------------------------------------+
    Absorbed FE | Categories  - Redundant  = Num. Coefs |
----------------+---------------------------------------|
 fe_countyqtroy |      6676        6676           0    *|
        fe_styr |       631           0         631     |
--------------------------------------------------------+
* = FE nested within cluster; treated as redundant for DoF computation
.                 summ pmil_qwi_emptotal [aw=seer_pop16plus] if e(sample)

    Variable |     Obs      Weight        Mean   Std. Dev.       Min        Max
-------------+-----------------------------------------------------------------
pmil_qwi_e~l |  74,725  1.1026e+10    643596.5   210020.4   120382.4    6745368
.                 local ymean=`r(mean)'
.                 regsave using "$Rep_smokelabor/2_analysis/output_tables/table1_c.dta", addlabel(KleibergenPaap_F, `e(rkf)', outcome_mean, "`ymean'") table(employment, `tbl_settings_pmil') append
file C:\Users\ericzou\Dropbox\replicate_smokelabor/2_analysis/output_tables/table1_c.dta saved
.                 
.                 * lfp
.                 ivreghdfe d_pmil_lau_lfp (pm25=hms_deep) [aw=seer_pop] , a(fe_countyqtroy fe_styr) cluster(countyfip fe_stqtros)
(dropped 189 singleton observations)
(sum of wgt is     1.4027e+10)
(MWFE estimator converged in 8 iterations)

IV (2SLS) estimation
--------------------

Estimates efficient for homoskedasticity only
Statistics robust to heteroskedasticity and clustering on countyfip and fe_stqtros

Number of clusters (countyfip) =   1686               Number of obs =    75193
Number of clusters (fe_stqtros) =   2548              F(  1,  1685) =    18.85
                                                      Prob > F      =   0.0000
Total (centered) SS     =  6.03036e+12                Centered R2   =  -0.0101
Total (uncentered) SS   =  6.03036e+12                Uncentered R2 =  -0.0101
Residual SS             =  6.09110e+12                Root MSE      =     9039

------------------------------------------------------------------------------
             |               Robust
d_pmil_lau~p |      Coef.   Std. Err.      t    P>|t|     [95% Conf. Interval]
-------------+----------------------------------------------------------------
        pm25 |  -790.8584   182.1385    -4.34   0.000      -1148.1    -433.617
------------------------------------------------------------------------------
Underidentification test (Kleibergen-Paap rk LM statistic):             52.381
                                                   Chi-sq(1) P-val =    0.0000
------------------------------------------------------------------------------
Weak identification test (Cragg-Donald Wald F statistic):             2857.845
                         (Kleibergen-Paap rk Wald F statistic):         71.695
Stock-Yogo weak ID test critical values: 10% maximal IV size             16.38
                                         15% maximal IV size              8.96
                                         20% maximal IV size              6.66
                                         25% maximal IV size              5.53
Source: Stock-Yogo (2005).  Reproduced by permission.
NB: Critical values are for Cragg-Donald F statistic and i.i.d. errors.
------------------------------------------------------------------------------
Hansen J statistic (overidentification test of all instruments):         0.000
                                                 (equation exactly identified)
------------------------------------------------------------------------------
Instrumented:         pm25
Excluded instruments: hms_deep
Partialled-out:       _cons
                      nb: total SS, model F and R2s are after partialling-out;
                          any small-sample adjustments include partialled-out
                          variables in regressor count K
------------------------------------------------------------------------------

Absorbed degrees of freedom:
--------------------------------------------------------+
    Absorbed FE | Categories  - Redundant  = Num. Coefs |
----------------+---------------------------------------|
 fe_countyqtroy |      6677        6677           0    *|
        fe_styr |       637           0         637     |
--------------------------------------------------------+
* = FE nested within cluster; treated as redundant for DoF computation
.                 summ pmil_lau_lfp [aw=seer_pop] if e(sample)

    Variable |     Obs      Weight        Mean   Std. Dev.       Min        Max
-------------+-----------------------------------------------------------------
pmil_lau_lfp |  75,193  1.4027e+10    631805.5   54155.91   184521.2    1322149
.                 local ymean=`r(mean)'
.                 regsave using "$Rep_smokelabor/2_analysis/output_tables/table1_c.dta", addlabel(KleibergenPaap_F, `e(rkf)', outcome_mean, "`ymean'") table(lfp, `tbl_settings_pmil') append
file C:\Users\ericzou\Dropbox\replicate_smokelabor/2_analysis/output_tables/table1_c.dta saved
.                 
.                 preserve 
.                         use "$Rep_smokelabor/2_analysis/output_tables/table1_c.dta", clear
.                         drop if var == "r2"
(1 observation deleted)
.                         drop if var == "_id"
(0 observations deleted)
.                         drop if strpos(var, "_cons_") > 0
(0 observations deleted)
.                         replace var="observations" if var=="N"
(1 real change made)
.                         ingap 3
.                         list , sep(0)

     +-------------------------------------------------------+
     |              var    earnings   employment         lfp |
     |-------------------------------------------------------|
  1. |        pm25_coef   -103.1***   -1750.1***   -790.9*** |
  2. |      pm25_stderr      (20.4)      (434.8)     (182.1) |
  3. |                                                       |
  4. |     observations      74,725       74,725      75,193 |
  5. | KleibergenPaap_F        71.8         71.2        71.7 |
  6. |     outcome_mean      5687.6     643596.5    631805.5 |
     +-------------------------------------------------------+
.                         saveold "$Rep_smokelabor/2_analysis/output_tables/table1_c.dta", replace
(saving in Stata 13 format)
(FYI, saveold has options version(12) and version(11) that write files in older Stata formats)
file C:\Users\ericzou\Dropbox\replicate_smokelabor/2_analysis/output_tables/table1_c.dta saved
.                 restore
.         
.         }

.         
. log close
      name:  <unnamed>
       log:  C:\Users\ericzou\Dropbox\replicate_smokelabor/2_analysis/output_logs/table1.log
  log type:  text
 closed on:  22 Jun 2022, 16:44:23
------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
